<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>

<body>

<form class="layui-form" lay-filter="gradeForm" id="add_grade_form" action="" style="padding:15px 10px;">
    <!--<input type="hidden" name="cmId">-->
    <!--<input type="hidden" name="photo" id="photo" class="layui-input">-->
    <div class="layui-form-item">
        <label class="layui-form-label">年级名称</label>
        <div class="layui-input-block">
            <input type="text" name="gradeName" required  lay-verify="required" placeholder="请输入年级名称" autocomplete="off" class="layui-input">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">所属园所</label>
        <!--<input type="text" name="glId">-->
        <div class="layui-input-block" id="g">
            <select name="gIId" id="glIdaa">
                <option value="-1">请选择</option>
            </select>
        </div>
    </div>



    <script>
        layui.form.render();
        $.get("http://localhost:9999/Graden/index",function(data){
            $.each(data.data,function(){
                var opt = $("<option></option>").appendTo("#glIdaa");
                opt.text(this.glName).val(this.glId);
            });
            layui.form.render()
        });

    </script>
</form>
</body>
</html>